A library to express information in a functional way that allows for easy auto-complete and shorter expressions. More...
#include <algorithm>#include <cstddef>#include <functional>#include <iterator>#include <map>#include <numeric>#include <optional>#include <random>#include <set>#include <stdexcept>#include <string>#include <tuple>#include <type_traits>#include <utility>#include <valarray>#include <variant>#include <vector>#include "asserts.h"#include "traits.h"#include "transforms.h"
Go to the source code of this file.
Classes | |
| class | fcpp::Queryable< T > |
| Core object used to query items and hold the sequence state. More... | |
| class | fcpp::Merge< TrueT, FalseT > |
| Merge result of both if and else block queries from Queryable<T>::branch method. More... | |
| class | fcpp::WhenFalse< WhenTrueQueriedT, T > |
| False / else block query of Queryable<T>::branch method. More... | |
| class | fcpp::WhenTrue< T > |
| True / if block query of Queryable<T>::branch method. More... | |
Macros | |
| #define | EXPR(...) |
| Syntactic sugar for terse expressions using pass by value. | |
| #define | CR_EXPR(...) |
| Syntactic sugar for terse expressions using pass by constant reference. | |
Functions | |
| template<typename T> | |
| Queryable< T > | fcpp::query (std::vector< T > items) |
| Queries the sequence of items using a vector. | |
Detailed Description
A library to express information in a functional way that allows for easy auto-complete and shorter expressions.
- Version
- 0.2
- Date
- 2026-10-21
- Copyright
- Copyright 2021 Google LLC
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
https://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
Macro Definition Documentation
◆ CR_EXPR
| #define CR_EXPR | ( | ... | ) |
Syntactic sugar for terse expressions using pass by constant reference.
- List of variable names passed in.
- Returns
- Produced value of the variables and operations evaluated.
◆ EXPR
| #define EXPR | ( | ... | ) |
Syntactic sugar for terse expressions using pass by value.
- List of variable names passed in.
- Returns
- Produced value of the variables and operations evaluated.
Function Documentation
◆ query()
| Queryable< T > fcpp::query | ( | std::vector< T > | items | ) |
Queries the sequence of items using a vector.
- Template Parameters
-
T Type of items to query over.
- Parameters
-
items Items to query over.
- Returns
- Queryable<T>