2
0
mirror of https://gitlab.com/ita1024/waf.git synced 2024-11-25 19:30:04 +01:00
waf/playground/erlang/hello.erl

37 lines
1.1 KiB
Erlang
Raw Normal View History

2011-09-10 11:13:51 +02:00
% what a weird language ... :-)
%%% @author Przemyslaw Rzepecki
%%% @version 0.01
%%% @doc == Hello World, Example Module ==
%%% This module contains some Erlang code for WAF build system support for
%%% Erlang language.
%%% @end
2011-09-10 11:13:51 +02:00
-module(hello).
-export([say_hello/1, hello_world/0]).
-include("hello.hrl").
%%% ###########################################################################
%% @doc Returns a greetings string
%%
%% Some more specific description of the function should be written here...
%%
%% See http://erlang.org/doc/apps/edoc/users_guide.html for the complete Edoc
%% guide.
%%
%% @end
%%% ----------------------------------------------------------
say_hello(waf) -> "Hello WAF, cool to see you!";
say_hello(make) -> "Oh Make, you again...";
say_hello(Other) -> "Hi " ++ Other.
%%% ###########################################################################
%% @doc Print a 'Hello World' string to stdout of the program..
%%
%% This is an Erlang Version of the famous hello_world function.
%%
%% @end
%%% ----------------------------------------------------------
hello_world() -> io:fwrite("~p~n", [?HELLO_WORLD]).