-
Notifications
You must be signed in to change notification settings - Fork 1
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
Showing
8 changed files
with
898 additions
and
825 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
1,659 changes: 836 additions & 823 deletions
1,659
src/Visp.Compiler/Syntax/FsLexYaccOutput/Parser.fs
Large diffs are not rendered by default.
Oops, something went wrong.
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
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
25 changes: 25 additions & 0 deletions
25
tests/Visp.Compiler.UnitTests/snapshots/tests_pats_fn-1.can parse.verified.txt
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,25 @@ | ||
// This file is auto-generated | ||
|
||
#nowarn "0020" // unused results from functions | ||
|
||
open Visp.Runtime.Library | ||
|
||
let state = { Todo = () } | ||
// line 8 @"fn-1.visp" | ||
let WithPred (pred: ('T -> bool)) t = | ||
// line 9 @"fn-1.visp" | ||
pred t | ||
|
||
// line 11 @"fn-1.visp" | ||
printfn "WithPred: %A" (WithPred ((fun arg1 -> | ||
// line 11 @"fn-1.visp" | ||
CoreMethods.``eq?``(arg1, 1))) 1) | ||
// line 12 @"fn-1.visp" | ||
printfn "WithPred: %A" (WithPred ((fun arg1 -> | ||
// line 12 @"fn-1.visp" | ||
CoreMethods.``eq?``(arg1, 1))) 0) | ||
// line 14 @"fn-1.visp" | ||
let visp_result_todo = () | ||
// line 14 @"fn-1.visp" | ||
printfn "%A" visp_result_todo | ||
|
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
5 changes: 5 additions & 0 deletions
5
tests/Visp.ExecutionTests/snapshots/tests_pats_fn-1.can execute.verified.txt
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,5 @@ | ||
WithPred: true | ||
WithPred: false | ||
() | ||
|
||
ExitCode: 0 |
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,14 @@ | ||
;; Copyright 2023 Ville Penttinen | ||
;; Distributed under the MIT License. | ||
;; https://github.com/vipentti/visp-fs/blob/main/LICENSE.md | ||
;; | ||
;; for basic syntax highlighting | ||
;; vim: set syntax=clojure: | ||
|
||
(fn WithPred ([pred: (^T -> bool)] t) | ||
(pred t)) | ||
|
||
(printfn "WithPred: %A" (WithPred #(= %1 1) 1)) | ||
(printfn "WithPred: %A" (WithPred #(= %1 1) 0)) | ||
|
||
() |