Home > Back-end >  An error happenes Whan I made two-dimensional array on Laravel. Signal9
An error happenes Whan I made two-dimensional array on Laravel. Signal9

Time:04-25

The error happened is

1/1) ProcessSignaledException The process has been signaled with signal "9".

     $foodListArr = array();
     $array = array('fruit'=> 'apple', 'amount'=> 10);
     array_push( $foodListArr,$array);

enter image description here

I expected it worked

     $foodListArr = array();
     $array = array('fruit'=> 'orange', 'amount'=> 10);
     array_push( $foodListArr,$array);
     $array = array('fruit'=> 'apple', 'amount'=> 5);
     array_push( $foodListArr,$array);
foodListArray[0]. 
It shows  array('fruit'=> 'orange', 'amount'=> 10).
foodListArray[1]. 
It shows  array('fruit'=> 'orange', 'amount'=> 10).

CodePudding user response:

This has nothing to do with PHP or Laravel code. It may be due to the depletion of your virtual memory(if you are using a VM, valet or etc).

In fact, this error is from memory space and you can solve this problem by freeing up memory.

  • Related