• Join/Login
  • Business Software
  • Open Source Software
  • For Vendors
  • Blog
  • About
  • More
    • Articles
    • Create
    • SourceForge Podcast
    • Site Documentation
    • Subscribe to our Newsletter
    • Support Request
SourceForge logo
For Vendors Help Create Join Login
SourceForge logo
Business Software
Open Source Software
SourceForge Podcast
Resources
  • Articles
  • Case Studies
  • Blog
Menu
  • Help
  • Create
  • Join
  • Login
  • Home
  • Browse
  • FMSLogo
  • Bugs
FMSLogo

NUMBER? outputs false for "|-1|

A Logo programming environment for Microsoft Windows

Brought to you by: david_costanzo
  • Summary
  • Files
  • Reviews
  • Support
  • Tickets ▾
    • Feature Requests
    • Bugs
    • Support Requests
  • Discussion
  • Code
Menu ▾ ▴
  • Create Ticket
  • View Stats

Group

  • v_6.06x
  • v_6.07.X
  • v_6.08.X
  • v_6.10.X
  • v_6.11.X
  • v_6.13.X
  • v_6.22.X
  • v_6.25.X
  • v_6.26.X
  • v_6.27.X
  • v_6.28.X
  • v_6.29.X

Searches

  • Changes
  • Closed Tickets
  • Open Tickets

Help

  • Formatting Help

#623 NUMBER? outputs false for "|-1|

v_6.06x
open
nobody
None
5
2026-06-21
2026-06-21
David Costanzo
No

The following output "true

NUMBER? -1
NUMBER? "-1
NUMBER? "\-\1

But NUMBER? "|-1| outputs false. The vertical barring is supposed to make sure that what's enclosed makes it into the word, so "|-1| shouldn't behave different from "-1, at least for numeric operations.

This also leads to procedures incorrectly rejecting vbarred numbers as malformed

? SHOW SUM 0 "|-1|
SUM doesn't like |-1| as input
? FORWARD "|-100|
FORWARD doesn't like |-100| as input

The problem happens for any vbarred words that are well-formed numbers which contain a + or a - character. For example

? SHOW NUMBER? "|1e+1|
false

This is reproducible in UCBLogo 6.2 and MSWLogo 6.5b.

I believe the bug is that numberp doesn't handle vbarred strings correctly and cnv_node_to_numnode assumes that it does.

It's also not clear why - and + are handled specially by the vertical bars. I suspect this was done without much thinking early on and never questioned later. A high risk, but simple, fix would be not to consider them as special characters.

Discussion


Log in to post a comment.

SourceForge
  • Create a Project
  • Open Source Software
  • Business Software
  • Top Downloaded Projects
Company
  • About
  • Team
  • SourceForge Headquarters
    1320 Columbia Street Suite 310
    San Diego, CA 92101
    +1 (858) 422-6466
Resources
  • Support
  • Site Documentation
  • Site Status
  • SourceForge Reviews
SourceForge logo
© 2026 Slashdot Media. All Rights Reserved.
Terms Privacy Opt Out Advertise
MongoDB Logo MongoDB