-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Jun FURUSE
committed
Nov 30, 2016
1 parent
f7d8a1f
commit c19270c
Showing
4 changed files
with
61 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
open Printf | ||
|
||
let () = | ||
let x = max_int in | ||
printf "max_int=%d\n%!" x; | ||
let s = Marshal.from_string (Marshal.to_string x []) 0 in | ||
printf "max_int=%d\n%!" s | ||
|
||
|
||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
|
||
** Conflict (shift/reduce/reduce) in state 1. | ||
** Tokens involved: WORD # | ||
** The following explanations concentrate on token WORD. | ||
** This state is reached from statement after reading: | ||
|
||
START | ||
|
||
** The derivations that appear below have the following common factor: | ||
** (The question mark symbol (?) represents the spot where the derivations begin to differ.) | ||
|
||
statement | ||
START sequence | ||
(?) | ||
|
||
** In state 1, looking ahead at WORD, reducing production | ||
** maybeword -> | ||
** is permitted because of the following sub-derivation: | ||
|
||
sequence WORD // lookahead token appears | ||
maybeword // lookahead token is inherited | ||
. | ||
|
||
** In state 1, looking ahead at WORD, shifting is permitted | ||
** because of the following sub-derivation: | ||
|
||
maybeword | ||
. WORD | ||
|
||
** In state 1, looking ahead at WORD, reducing production | ||
** sequence -> | ||
** is permitted because of the following sub-derivation: | ||
|
||
sequence WORD // lookahead token appears | ||
. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
exception Error | ||
|
||
type token = | ||
| WORD | ||
| START | ||
|
||
|
||
val statement: (Lexing.lexbuf -> token) -> Lexing.lexbuf -> (int) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
#!/bin/sh | ||
|
||
X=`ocamlfind query unix` | ||
echo X="$X" | ||
Y="-I $X hello" | ||
echo Y=$Y | ||
ocaml $Y |