Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
S
sv2v
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
lvzhengyang
sv2v
Commits
bb938f1e
Commit
bb938f1e
authored
Jun 25, 2021
by
Zachary Snow
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
add ability to --pass-through input without conversion
parent
3f20055c
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
7 additions
and
2 deletions
+7
-2
README.md
+1
-0
src/Job.hs
+2
-0
src/sv2v.hs
+4
-2
No files found.
README.md
View file @
bb938f1e
...
...
@@ -92,6 +92,7 @@ Preprocessing:
--siloed Lex input files separately, so macros from
earlier files are not defined in later files
--skip-preprocessor Disable preprocessor
--pass-through Dump input without converting
Conversion:
-E --exclude=CONV Exclude a particular conversion (always, assert,
interface, or logic)
...
...
src/Job.hs
View file @
bb938f1e
...
...
@@ -38,6 +38,7 @@ data Job = Job
,
define
::
[
String
]
,
siloed
::
Bool
,
skipPreprocessor
::
Bool
,
passThrough
::
Bool
,
exclude
::
[
Exclude
]
,
verbose
::
Bool
,
write
::
Write
...
...
@@ -61,6 +62,7 @@ defaultJob = Job
,
siloed
=
nam_
"siloed"
&=
help
(
"Lex input files separately, so"
++
" macros from earlier files are not defined in later files"
)
,
skipPreprocessor
=
nam_
"skip-preprocessor"
&=
help
"Disable preprocessor"
,
passThrough
=
nam_
"pass-through"
&=
help
"Dump input without converting"
,
exclude
=
nam_
"exclude"
&=
name
"E"
&=
typ
"CONV"
&=
help
(
"Exclude a particular conversion (always, assert, interface,"
++
" or logic)"
)
...
...
src/sv2v.hs
View file @
bb938f1e
...
...
@@ -88,8 +88,10 @@ main = do
hPutStrLn
stderr
msg
exitFailure
Right
asts
->
do
-- convert the files
let
asts'
=
convert
(
exclude
job
)
asts
-- convert the files if requested
let
asts'
=
if
passThrough
job
then
asts
else
convert
(
exclude
job
)
asts
emptyWarnings
(
concat
asts
)
(
concat
asts'
)
-- write the converted files out
writeOutput
(
write
job
)
(
files
job
)
asts'
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment