Blinq
Burst-compatible LINQ extensions for NativeArray that provide deferred, stack-allocated query operations. Enables functional programming patterns in performance-critical code by using struct-based function implementations instead of delegates, allowing full Burst compiler optimization for high-performance gameplay systems.
com.careboo.blinq 
Install via UPM
Add to Unity Package Manager using this URL
https://www.pkglnk.dev/blinq.git?path=Packages/com.careboo.blinq README Markdown
Copy this to your project's README.md
## Installation
Add **Blinq** to your Unity project via Package Manager:
1. Open **Window > Package Manager**
2. Click **+** > **Add package from git URL**
3. Enter:
```
https://www.pkglnk.dev/blinq.git?path=Packages%2Fcom.careboo.blinq
```
[](https://www.pkglnk.dev/pkg/blinq)Dependencies (2)
README
Blinq
IMPORTANT: Blinq is no longer being developed because of limitations to recursive generics. Instead, I recommend taking a look at the LinqGen project.
Burst Compatible, deferred, stack-allocated LINQ extensions for NativeArray.
Installation
This project can be installed as a UPM package. The easiest way to install it right now is using the OpenUPM.
Currently, support for the Github Package Registry is broken. See this thread here for more information.
Differences with Linq
Delegates
The Burst compiler doesn't support C# delegates. To get around this issue, Blinq requires you to create structs that implement the IFunc interface. The Burst.Delegates project has other useful tools to help you implement the IFunc interface.
/*--- Using Linq ---*/
var selected = myArray.Select(val => val.Item);
/*--- Using Blinq ---*/
// Must define a method that can be used as FunctionPointer
[BurstCompile]
public static int SelectItem(MyVal val) => val.Item;
public static readonly BurstFunc<MyVal, int> SelectItemFunc = BustFunc<MyVal, int>.Compile(SelectItem);
// Now we can finally call ``Select``
var selected = myArray.Select(SelectItemFunc);
No comments yet. Be the first!