lecture 05

This commit is contained in:
SowinskiBraeden committed 2026-10-14 16:26:51 -07:00
1 parent cda6101a3d
commit 6c54e7a49b
7 files changed
+175

No files matched your search

+16
View File
@@ -0,0 +1,16 @@
defmodule M do
defmacro say(msg) do
name = String.to_atom("say_#{msg}")
quote do
def name() do
IO.puts(unquote(msg))
end
end
end
end
defmodule Test do
import M
say("hello")
end