Summary

scrutinizer makes too strong assumptions about mutable data

Metadata

Description

Like this:

 (define foo (make-vector 1 #f))
 (vector-set! foo 0 'sym)
 (print (get (vector-ref foo 0) 'a))

When compiled in block mode, we get:

 Warning: at toplevel:
   (x.scm:5) in procedure call to `get', expected argument #1 of type `symbol', but was given an argument of type `boolean'

Changes and comments

[2012-06-15 13:15:51 UTC] felix changed description

[2012-06-15 14:49:15 UTC] felix changed priority from major to critical

[2012-06-15 14:49:15 UTC] felix set milestone to 4.8.0

[2012-06-15 14:49:15 UTC] felix wrote:

The entries for `make-vector` and `cons`, `list` and all other constructors probably have to be weakened in `types.db` - the returned data may be mutated and so can change type.

[2012-06-16 13:59:18 UTC] felix wrote:

Replying to felix: > The entries for `make-vector` and `cons`, `list` and all other constructors probably have to be weakened in `types.db` - the returned data may be mutated and so can change type.

That's nonsense, actually. The real problem is that smashing happens only for env + blist entries, not for globals.

[2012-06-28 13:47:51 UTC] felix changed status from new to closed

[2012-06-28 13:47:51 UTC] felix set resolution to fixed

[2012-06-28 13:47:51 UTC] felix wrote:

Pushed to master in ae6af2c1894b8ab8178f21f8169a98c3b5e0327a.

[2012-09-24 21:47:48 UTC] felix wrote:

Milestone 4.8.0 deleted

[2012-09-24 21:47:48 UTC] felix changed milestone from 4.8.0 to 4.9.0