Skip to content

Commit

Permalink
interpreter/compiler: Fortran.run() has always worked
Browse files Browse the repository at this point in the history
This incorrectly warns that `compiler.run()` is new in 1.5.0 for
Fortran, but that works fine for older versions (noted with 1.2.3). This
makes sense, as FortranCompiler inherits CLikeCompiler
  • Loading branch information
dcbaker authored and xclaesse committed Apr 5, 2024
1 parent d86fce9 commit e455cb0
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions mesonbuild/interpreter/compiler.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# SPDX-License-Identifier: Apache-2.0
# Copyright 2012-2021 The Meson development team
# Copyright © 2021 Intel Corporation
# Copyright © 2021-2024 Intel Corporation
from __future__ import annotations

import collections
Expand Down Expand Up @@ -302,7 +302,7 @@ def alignment_method(self, args: T.Tuple[str], kwargs: 'AlignmentKw') -> int:
@typed_pos_args('compiler.run', (str, mesonlib.File))
@typed_kwargs('compiler.run', *_COMPILES_KWS)
def run_method(self, args: T.Tuple['mesonlib.FileOrString'], kwargs: 'CompileKW') -> 'RunResult':
if self.compiler.language not in {'d', 'c', 'cpp', 'objc', 'objcpp'}:
if self.compiler.language not in {'d', 'c', 'cpp', 'objc', 'objcpp', 'fortran'}:
FeatureNew.single_use(f'compiler.run for {self.compiler.get_display_language()} language',
'1.5.0', self.subproject, location=self.current_node)
code = args[0]
Expand Down

0 comments on commit e455cb0

Please sign in to comment.