Possible bug in SequencePoint - StartLine value off the charts #80

Closed
opened 2011-10-28 00:48:34 -05:00 by provegard · 2 comments
provegard commented 2011-10-28 00:48:34 -05:00 (Migrated from github.com)

I've been using Cecil in a hobby project, and overall it works great! I found something odd when studying the sequence points of one of my test methods. The start lines of the sequence points are:

nop : 13
newobj : 14
newobj : 16
ldloc.1 : 17
ldloc.2 : 16707566
ldstr : 20
br.s : 21
ldstr : 23
br.s : 24
ret : 26

The ldloc.2 instruction stands out a bit there... It seems to me that it's a bug, but I know too little about Cecil and CIL to say for sure what's going on.

I have created a tiny VS2010 solution that demonstrates the problem. Simply run from within VS and you should get the printout as above:

https://github.com/provegard/CecilSeqPointBug

I've been using Cecil in a hobby project, and overall it works great! I found something odd when studying the sequence points of one of my test methods. The start lines of the sequence points are: nop : 13 newobj : 14 newobj : 16 ldloc.1 : 17 ldloc.2 : 16707566 ldstr : 20 br.s : 21 ldstr : 23 br.s : 24 ret : 26 The ldloc.2 instruction stands out a bit there... It seems to me that it's a bug, but I know too little about Cecil and CIL to say for sure what's going on. I have created a tiny VS2010 solution that demonstrates the problem. Simply run from within VS and you should get the printout as above: https://github.com/provegard/CecilSeqPointBug
jbevain commented 2011-10-28 00:59:45 -05:00 (Migrated from github.com)

Hey,

Thanks for the bug and the repro, but this time I'm lucky, it's no bug.
See http://blogs.msdn.com/b/jmstall/archive/2005/06/19/feefee-sequencepoints.aspx

Thanks!

Hey, Thanks for the bug and the repro, but this time I'm lucky, it's no bug. See http://blogs.msdn.com/b/jmstall/archive/2005/06/19/feefee-sequencepoints.aspx Thanks!
provegard commented 2011-10-28 01:24:16 -05:00 (Migrated from github.com)

Thanks for the link! Shame on me for not googling this in advance!

Thanks for the link! Shame on me for not googling this in advance!
Sign in to join this conversation.
No milestone
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
gh-jbevain/cecil#80
No description provided.