• Skip to main content
  • Skip to search
  • Skip to footer
Cadence Home
  • This search text may be transcribed, used, stored, or accessed by our third-party service providers per our Cookie Policy and Privacy Policy.

  1. Community Forums
  2. Custom IC SKILL
  3. sprint does not accept nil returned from expression

Stats

  • Locked Locked
  • Replies 3
  • Subscribers 143
  • Views 14280
  • Members are here 0
This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

sprint does not accept nil returned from expression

liorscotland
liorscotland over 8 years ago

Hello all.
See this behaviour (6.1.6) in SKILL, straight from the CIW (toplevel is 'ils):
It would appear that if the first argument is nil returned from an expression, sprintf won't accept it.
However, "direct" nil works like a charm...
See CIW log below: if( 1== 0 t nil ) ireturns nil, but not accepted as 1st argument to sprint:

sprintf( if( 1==0 t nil ) "yo!\n" )
*Error* sprintf: argument #1 must be a symbol or nil - if((1 == 0) t nil)

if( 1==0 t nil )
nil
sprintf( nil "yo!\n" )
"yo!\n"

Thanks.

  • Cancel
Parents
  • Andrew Beckett
    Andrew Beckett over 8 years ago

    Hi Lior,

    If it's a macro, I'm sure there's no need to do this. Can you share the macro? Maybe if not on the forums, you can send it to me directly?

    A syntax form is something that is built-in to the language - essentially it doesn't evaluate its arguments before it is called (like a normal "lambda" function), but the function can choose which arguments should be evaluated. So language features like procedure, setq, let etc are syntax forms.

    Regards,

    Andrew.

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
Reply
  • Andrew Beckett
    Andrew Beckett over 8 years ago

    Hi Lior,

    If it's a macro, I'm sure there's no need to do this. Can you share the macro? Maybe if not on the forums, you can send it to me directly?

    A syntax form is something that is built-in to the language - essentially it doesn't evaluate its arguments before it is called (like a normal "lambda" function), but the function can choose which arguments should be evaluated. So language features like procedure, setq, let etc are syntax forms.

    Regards,

    Andrew.

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
Children
No Data

Community Guidelines

The Cadence Design Communities support Cadence users and technologists interacting to exchange ideas, news, technical information, and best practices to solve problems and get the most from Cadence technology. The community is open to everyone, and to provide the most value, we require participants to follow our Community Guidelines that facilitate a quality exchange of ideas and information. By accessing, contributing, using or downloading any materials from the site, you agree to be bound by the full Community Guidelines.

© 2025 Cadence Design Systems, Inc. All Rights Reserved.

  • Terms of Use
  • Privacy
  • Cookie Policy
  • US Trademarks
  • Do Not Sell or Share My Personal Information