Skip to content

Commit

Permalink
Remove ABSL_ATTRIBTUE_PURE_FUNCTION for non-trivial return types
Browse files Browse the repository at this point in the history
PiperOrigin-RevId: 647688651
  • Loading branch information
jcking authored and copybara-github committed Jun 28, 2024
1 parent bbed662 commit 68b2423
Show file tree
Hide file tree
Showing 5 changed files with 12 additions and 12 deletions.
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

0 comments on commit 68b2423

Please # to comment.