Skip to content

Instantly share code, notes, and snippets.

View nilpunch's full-sized avatar

Daniil Pankevich nilpunch

View GitHub Profile
using System;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;
namespace Massive
{
/// <summary>
/// 12-byte.
/// </summary>
[StructLayout(LayoutKind.Sequential)]
@nilpunch
nilpunch / Query.cs
Created March 14, 2026 11:21
New iteration algo
public void ForEach<T1, T2, T3, T4, TAction>(ref TAction action)
where TAction : IEntityAction<T1, T2, T3, T4>
{
NoDataException.ThrowIfHasNoData<T1>(World, DataAccessContext.View);
NoDataException.ThrowIfHasNoData<T2>(World, DataAccessContext.View);
NoDataException.ThrowIfHasNoData<T3>(World, DataAccessContext.View);
NoDataException.ThrowIfHasNoData<T4>(World, DataAccessContext.View);
var dataSet1 = World.DataSet<T1>();
var dataSet2 = World.DataSet<T2>();