Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
GHC
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Locked Files
Issues
4,324
Issues
4,324
List
Boards
Labels
Service Desk
Milestones
Iterations
Merge Requests
360
Merge Requests
360
Requirements
Requirements
List
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Security & Compliance
Security & Compliance
Dependency List
License Compliance
Operations
Operations
Incidents
Environments
Analytics
Analytics
CI / CD
Code Review
Insights
Issue
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Glasgow Haskell Compiler
GHC
Commits
9a3c8740
Commit
9a3c8740
authored
Feb 25, 2012
by
Ian Lynagh
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add a test for FFI decl parsing
We were parsing "staticfoo" as "static foo".
parent
ab91cded
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
22 additions
and
0 deletions
+22
-0
testsuite/tests/ffi/should_run/all.T
testsuite/tests/ffi/should_run/all.T
+5
-0
testsuite/tests/ffi/should_run/ffi_parsing_001.hs
testsuite/tests/ffi/should_run/ffi_parsing_001.hs
+8
-0
testsuite/tests/ffi/should_run/ffi_parsing_001.stdout
testsuite/tests/ffi/should_run/ffi_parsing_001.stdout
+1
-0
testsuite/tests/ffi/should_run/ffi_parsing_001_c.c
testsuite/tests/ffi/should_run/ffi_parsing_001_c.c
+8
-0
No files found.
testsuite/tests/ffi/should_run/all.T
View file @
9a3c8740
...
...
@@ -201,3 +201,8 @@ test('Capi_Ctype_002',
run_command
,
['
$MAKE -s --no-print-directory Capi_Ctype_002
'])
test
('
ffi_parsing_001
',
extra_clean
(['
ffi_parsing_001_c.o
']),
compile_and_run
,
['
ffi_parsing_001_c.c
'])
testsuite/tests/ffi/should_run/ffi_parsing_001.hs
0 → 100644
View file @
9a3c8740
import
Foreign.C
-- This should not be parsed as "static foo", importing "foo"
foreign
import
ccall
"staticfoo"
x
::
CInt
main
::
IO
()
main
=
print
x
testsuite/tests/ffi/should_run/ffi_parsing_001.stdout
0 → 100644
View file @
9a3c8740
5
testsuite/tests/ffi/should_run/ffi_parsing_001_c.c
0 → 100644
View file @
9a3c8740
int
staticfoo
(
void
)
{
return
5
;
}
int
foo
(
void
)
{
return
8
;
}
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