Skip to content

Instantly share code, notes, and snippets.

@mattfreer mattfreer/bad_template.eex
Last active Oct 12, 2015

What would you like to do?
Since upgrading to Elixir 1.1 and Eralang 18, I'm noticing that Dialyzer has some issues with String interpolation. This Gist demonstrates an issue with EEx templates that map over a list of Strings
<%= arbitrary_list, fn(item) -> %>
<%= item %>
<%= end %>
bad_template.eex:5: Guard test is_binary(_@2::[any()]) can never succeed
defmodule Scaffold do
require EEx
Path.expand("bad_template.eex", "lib/templates"),
def build do
template = bad_template(["foo", "bar"])
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.