Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Remove ABSL_ATTRIBTUE_PURE_FUNCTION for non-trivial return types #800

Merged
merged 1 commit into from
Jun 28, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions base/internal/unknown_set.h
Original file line number Diff line number Diff line change
Expand Up @@ -45,9 +45,9 @@ struct UnknownSetRep final {
FunctionResultSet function_results;
};

ABSL_ATTRIBUTE_PURE_FUNCTION const AttributeSet& EmptyAttributeSet();
const AttributeSet& EmptyAttributeSet();

ABSL_ATTRIBUTE_PURE_FUNCTION const FunctionResultSet& EmptyFunctionResultSet();
const FunctionResultSet& EmptyFunctionResultSet();

struct UnknownSetAccess;

Expand Down
6 changes: 3 additions & 3 deletions common/types/types.h
Original file line number Diff line number Diff line change
Expand Up @@ -226,11 +226,11 @@ template <typename T>
using BaseTypeViewAlternativeForT =
typename BaseTypeViewAlternativeFor<T>::type;

ABSL_ATTRIBUTE_PURE_FUNCTION ListTypeView GetDynListType();
ListTypeView GetDynListType();

ABSL_ATTRIBUTE_PURE_FUNCTION MapTypeView GetDynDynMapType();
MapTypeView GetDynDynMapType();

ABSL_ATTRIBUTE_PURE_FUNCTION OptionalTypeView GetDynOptionalType();
OptionalTypeView GetDynOptionalType();

} // namespace common_internal

Expand Down
4 changes: 2 additions & 2 deletions common/values/optional_value.h
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@ class OptionalValue final : public OpaqueValue {
using interface_type = OptionalValueInterface;
using view_alternative_type = OptionalValueView;

ABSL_ATTRIBUTE_PURE_FUNCTION static OptionalValue None();
static OptionalValue None();

static OptionalValue Of(MemoryManagerRef memory_manager, cel::Value value);

Expand Down Expand Up @@ -165,7 +165,7 @@ class OptionalValueView final : public OpaqueValueView {
using interface_type = OptionalValueInterface;
using alternative_type = OptionalValue;

ABSL_ATTRIBUTE_PURE_FUNCTION static OptionalValueView None();
static OptionalValueView None();

OptionalValueView() : OptionalValueView(None()) {}

Expand Down
2 changes: 1 addition & 1 deletion common/values/unknown_value.h
Original file line number Diff line number Diff line change
Expand Up @@ -140,7 +140,7 @@ inline std::ostream& operator<<(std::ostream& out, const UnknownValue& value) {

class UnknownValueView final {
private:
ABSL_ATTRIBUTE_PURE_FUNCTION static const Unknown& Empty();
static const Unknown& Empty();

public:
using alternative_type = UnknownValue;
Expand Down
8 changes: 4 additions & 4 deletions common/values/values.h
Original file line number Diff line number Diff line change
Expand Up @@ -502,13 +502,13 @@ template <typename T>
using BaseStructValueViewAlternativeForT =
typename BaseStructValueViewAlternativeFor<T>::type;

ABSL_ATTRIBUTE_PURE_FUNCTION ErrorValueView GetDefaultErrorValue();
ErrorValueView GetDefaultErrorValue();

ABSL_ATTRIBUTE_PURE_FUNCTION ParsedListValueView GetEmptyDynListValue();
ParsedListValueView GetEmptyDynListValue();

ABSL_ATTRIBUTE_PURE_FUNCTION ParsedMapValueView GetEmptyDynDynMapValue();
ParsedMapValueView GetEmptyDynDynMapValue();

ABSL_ATTRIBUTE_PURE_FUNCTION OptionalValueView GetEmptyDynOptionalValue();
OptionalValueView GetEmptyDynOptionalValue();

absl::Status ListValueEqual(ValueManager& value_manager, ListValueView lhs,
ListValueView rhs, Value& result);
Expand Down