mirror of
https://github.com/kovidgoyal/kitty.git
synced 2026-08-27 03:42:49 +00:00
Unify compilation_database access
`file` and `arguments` are accessed using the square bracket syntax, while `output` is accessed using `.get()`. This commit uses square brackets for all three. This will throw a `KeyError` if `compilation_database` does not have the key, which is the correct behaviour IMO.
This commit is contained in:
parent
7598a2965c
commit
4708b592e2
1 changed files with 1 additions and 1 deletions
2
setup.py
2
setup.py
|
|
@ -428,7 +428,7 @@ class CompilationDatabase:
|
|||
except FileNotFoundError:
|
||||
compilation_database = []
|
||||
compilation_database = {
|
||||
CompileKey(k['file'], k.get('output')): k['arguments'] for k in compilation_database
|
||||
CompileKey(k['file'], k['output']): k['arguments'] for k in compilation_database
|
||||
}
|
||||
self.db = compilation_database
|
||||
return self
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue