aboutsummaryrefslogtreecommitdiff
path: root/example_project
diff options
context:
space:
mode:
Diffstat (limited to 'example_project')
-rw-r--r--example_project/app/hello_world.f907
-rw-r--r--example_project/src/hello_m.f9012
2 files changed, 19 insertions, 0 deletions
diff --git a/example_project/app/hello_world.f90 b/example_project/app/hello_world.f90
new file mode 100644
index 0000000..b95062d
--- /dev/null
+++ b/example_project/app/hello_world.f90
@@ -0,0 +1,7 @@
+program hello_world
+ use hello_m, only: sayHello
+
+ implicit none
+
+ call sayHello("World")
+end program hello_world
diff --git a/example_project/src/hello_m.f90 b/example_project/src/hello_m.f90
new file mode 100644
index 0000000..a341602
--- /dev/null
+++ b/example_project/src/hello_m.f90
@@ -0,0 +1,12 @@
+module hello_m
+ implicit none
+ private
+
+ public :: sayHello
+contains
+ subroutine sayHello(name)
+ character(len=*), intent(in) :: name
+
+ print *, "Hello, " // name // "!"
+ end subroutine sayHello
+end module hello_m