• source navigation  • diff markup  • identifier search  • freetext search  • 

Sources/ucode/tests/custom/99_bugs/04_property_set_abort

  1 When attempting to set a property on a non-array, non-object value the
  2 VM aborted due to an assert triggered by libjson-c.
  3 
  4 -- Testcase --
  5 {% (null).x = 1 %}
  6 -- End --
  7 
  8 -- Expect stderr --
  9 Type error: attempt to set property on null value
 10 In line 1, byte 15:
 11 
 12  `{% (null).x = 1 %}`
 13   Near here ----^
 14 
 15 
 16 -- End --
 17 
 18 
 19 -- Testcase --
 20 {% (1).x = 1 %}
 21 -- End --
 22 
 23 -- Expect stderr --
 24 Type error: attempt to set property on integer value
 25 In line 1, byte 12:
 26 
 27  `{% (1).x = 1 %}`
 28   Near here -^
 29 
 30 
 31 -- End --
 32 
 33 
 34 -- Testcase --
 35 {% (1.2).x = 1 %}
 36 -- End --
 37 
 38 -- Expect stderr --
 39 Type error: attempt to set property on double value
 40 In line 1, byte 14:
 41 
 42  `{% (1.2).x = 1 %}`
 43   Near here ---^
 44 
 45 
 46 -- End --
 47 
 48 
 49 -- Testcase --
 50 {% (true).x = 1 %}
 51 -- End --
 52 
 53 -- Expect stderr --
 54 Type error: attempt to set property on boolean value
 55 In line 1, byte 15:
 56 
 57  `{% (true).x = 1 %}`
 58   Near here ----^
 59 
 60 
 61 -- End --
 62 
 63 
 64 -- Testcase --
 65 {% ("test").x = 1 %}
 66 -- End --
 67 
 68 -- Expect stderr --
 69 Type error: attempt to set property on string value
 70 In line 1, byte 17:
 71 
 72  `{% ("test").x = 1 %}`
 73   Near here ------^
 74 
 75 
 76 -- End --

This page was automatically generated by LXR 0.3.1.  •  OpenWrt