public void EnclosedWhile(int max1, int max2)
{
int number1 = 0;
while (number1 < max1)
{
int number2 = 0;
while (number2 < max2)
{
Console.WriteLine(number1 + number2);
++number2;
}
++number1;
}
}
void WhileStatements::EnclosedWhile(int32_t max1, int32_t max2)
{
int32_t number1 = 0;
while (number1 < max1)
{
int32_t number2 = 0;
while (number2 < max2)
{
System::Console::WriteLine(number1 + number2);
++number2;
}
++number1;
}
}
public class ClassProperties
{
public string PublicProperty
{
get { return mPublicPropertyField; }
set { mPublicPropertyField = value; }
}
private string mPublicPropertyField;
}
class ClassProperties : public System::Object
{
public:
System::String get_PublicProperty();
void set_PublicProperty(System::String value);
ClassProperties();
private:
System::String mPublicPropertyField;
};
public void BreakEnclosedForeach(int[][] values, int max)
{
foreach (int[] row in values)
{
if (row.Length == 0)
{
break;
}
foreach (int value in row)
{
Console.WriteLine(value);
if (value > max)
{
break;
}
}
}
}
void BreakStatements::BreakEnclosedForeach(System::ArrayPtr<System::ArrayPtr<int32_t>> values, int32_t max)
{
for (System::ArrayPtr<System::ArrayPtr> row : values)
{
if (row->get_Length() == 0)
{
break;
}
for (int32_t value : row)
{
System::Console::WriteLine(value);
if (value > max)
{
break;
}
}
}
}
using System.Threading;
class LambdaTest
{
public void TestMPMM_1()
{
var a = 0;
new Thread(() =>
{
var b = a;
});
}
}
#include <system/threading/thread.h>
#include <system/details/lambda_capture_holder.h>
#include <functional>
#include <cstdint>
void LambdaTest::TestMPMM_1()
{
System::Details::LambdaCaptureHolder<int32_t> _lch_a = 0;
int32_t &a = _lch_a.GetCapture();
System::MakeObject<System::Threading::Thread>(static_cast<System::Threading::ThreadStart>(static_cast<std::function<void()>>([_lch_a, &a]() -> void
{
int32_t b = a;
})).template AddHeldVariable<System::Threading::ThreadStart>("a", a));
}