2
// Copyright (c) 2012 The ANGLE Project Authors. All rights reserved.
3
// Use of this source code is governed by a BSD-style license that can be
4
// found in the LICENSE file.
7
#ifndef COMPILER_PREPROCESSOR_SOURCE_LOCATION_H_
8
#define COMPILER_PREPROCESSOR_SOURCE_LOCATION_H_
15
SourceLocation() : file(0), line(0) { }
16
SourceLocation(int f, int l) : file(f), line(l) { }
18
bool equals(const SourceLocation& other) const
20
return (file == other.file) && (line == other.line);
27
inline bool operator==(const SourceLocation& lhs, const SourceLocation& rhs)
29
return lhs.equals(rhs);
32
inline bool operator!=(const SourceLocation& lhs, const SourceLocation& rhs)
34
return !lhs.equals(rhs);
38
#endif // COMPILER_PREPROCESSOR_SOURCE_LOCATION_H_