louise
The Louise language: compiler, runtime, std, tooling
Clone avec HTTPS, un jeton personnel en mot de passe, ou avec SSH, une clé ajoutée dans vos paramètres.
Dernier runRéussi#121 · main · 16 min 23 s
0Étoiles
0Forks
40Issues
| 1 | // An overflowing conversion stops the actor, on both backends (money |
| 2 | // must not wrap, ADR 0070). |
| 3 | |
| 4 | import std/dec |
| 5 | import std/int |
| 6 | import std/io |
| 7 | |
| 8 | pub fn main :: -> () / <io> |
| 9 | { |
| 10 | io.println "{dec.from_int 42}" |
| 11 | io.println "never printed {dec.from_int (int.shift_left 1 100)}" |
| 12 | } |
| 13 | //> 42 |
| 14 | //! panic: dec.from_int: overflow |