<commit_before>package reflect

import (
	lua "github.com/anaminus/gopher-lua"
	"github.com/anaminus/rbxmk"
	"github.com/anaminus/rbxmk/dump"
	"github.com/anaminus/rbxmk/dump/dt"
	"github.com/anaminus/rbxmk/rtypes"
	"github.com/robloxapi/types"
)

func init() { register(DirEntry) }
func DirEntry() rbxmk.Reflector {
	return rbxmk.Reflector{
		Name: rtypes.T_DirEntry,
		PushTo: func(c rbxmk.Context, v types.Value) (lv lua.LValue, err error) {
			options, ok := v.(rtypes.DirEntry)
			if !ok {
				return nil, rbxmk.TypeError{Want: rtypes.T_DirEntry, Got: v.Type()}
			}
			table := c.CreateTable(0, 4)
			if err := c.PushToDictionary(table, "Name", types.String(options.Name())); err != nil {
				return nil, err
			}
			if err := c.PushToDictionary(table, "IsDir", types.Bool(options.IsDir())); err != nil {
				return nil, err
			}<commit_msg>Fix initialized size of DirEntry.<commit_after>package reflect

import (
	lua "github.com/anaminus/gopher-lua"
	"github.com/anaminus/rbxmk"
	"github.com/anaminus/rbxmk/dump"
	"github.com/anaminus/rbxmk/dump/dt"
	"github.com/anaminus/rbxmk/rtypes"
	"github.com/robloxapi/types"
)

func init() { register(DirEntry) }
func DirEntry() rbxmk.Reflector {
	return rbxmk.Reflector{
		Name: rtypes.T_DirEntry,
		PushTo: func(c rbxmk.Context, v types.Value) (lv lua.LValue, err error) {
			options, ok := v.(rtypes.DirEntry)
			if !ok {
				return nil, rbxmk.TypeError{Want: rtypes.T_DirEntry, Got: v.Type()}
			}
			table := c.CreateTable(0, 2)
			if err := c.PushToDictionary(table, "Name", types.String(options.Name())); err != nil {
				return nil, err
			}
			if err := c.PushToDictionary(table, "IsDir", types.Bool(options.IsDir())); err != nil {
				return nil, err
			}
{'fraction_non_alphanumeric': 0.15810968494749125, 'fraction_numerical': 0.002333722287047841, 'mean_word_length': 3.9566473988439306, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6676115', 'n_tokens_mistral': 730, 'n_tokens_neox': 672, 'n_words': 130}