Skip to content

Commit 82da86a

Browse files
committed
Updated System and Mix to use __record__(:index) syntax
1 parent c1a7c03 commit 82da86a

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

lib/elixir/lib/system.ex

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -162,8 +162,8 @@ defmodule System do
162162
defp write_tmp_dir(dir) do
163163
case :file.read_file_info(dir) do
164164
{:ok, info} ->
165-
type_index = File.Stat.__index__ :type
166-
access_index = File.Stat.__index__ :access
165+
type_index = File.Stat.__record__(:index, :type)
166+
access_index = File.Stat.__record__(:index, :access)
167167
case { elem(info, type_index), elem(info, access_index) } do
168168
{ :directory, access } when access in [:read_write, :write] ->
169169
dir

lib/mix/lib/mix/deps.ex

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,7 @@ defmodule Mix.Deps do
8282
deps = Enum.filter all_deps, fn(dep) -> dep.app in apps end
8383

8484
# Now we validate the given atoms
85-
index = Mix.Dep.__index__(:app)
85+
index = Mix.Dep.__record__(:index, :app)
8686
Enum.each apps, fn(app) ->
8787
unless List.keyfind(deps, app, index) do
8888
Mix.shell.info "unknown dependency #{app} for env #{Mix.env}"

0 commit comments

Comments
 (0)