Dr. Geo VM crash with Cherry Tree script

Bug #1532409 reported by hilaire on 2016-01-09
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Dr. Geo II

Bug Description

The enclosed script crash the Dr. Geo VM:

| canvas tree angl angr fac|
canvas := DrGeoCanvas new fullscreen.
fac := (canvas freeValue: 2/3) hide.
angl := (canvas freeValue: 2.8) hide.
angr := (canvas freeValue: -2.8) hide.

tree := [ ].
tree := [ :a :b :k | | ab m v bm lbc rbc lb rb mb |
 "construction of the tree"

 ab := canvas segment: a to: b.
 m := (canvas middleOf: ab) hide.
 v := (canvas vector: b to: m) hide.
 bm := (canvas scale: ab center: b factor: fac) hide.
 lbc := canvas rotate: bm center: b angle: angr.
 rbc := canvas rotate: bm center: b angle: angl.
 canvas translate: lbc vector: v.
 lb := (canvas rotate: m center: b angle: angr) .
 rb := (canvas rotate: m center: b angle: angl) .
 mb := (canvas translate: rb vector: v) .
 k > 0 ifTrue: [
  tree value: m value: mb value: k - 1.
  tree value: b value: lb value: k - 1.
  tree value: b value: rb value: k - 1]].
tree value: 0@0 value: 0@6 value: 4

hilaire (hilaire-fernandes) wrote :

The following patch fix the problem: (it is a retro fit for Pharo 4/5, thanks Nicolai Hess).
It should be applied this way:

SmalltalkImage compilerClass: Compiler.
'opal_drgeo.cs' asFileReference fileIn.
SmalltalkImage compilerClass: OpalCompiler.

Changed in drgeo:
milestone: wip → 16.03
Changed in drgeo:
status: New → Fix Committed
Changed in drgeo:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers

Bug attachments