GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — `TypeError: internref expected` when map is passed to a function · Issue #2769 · AssemblyScript/assemblyscript

TypeError: internref expected when map is passed to a function #2769

New issue
Copy link
New issue
Copy link
Open
Open
TypeError: internref expected when map is passed to a function#2769
Copy link
Labels
bug

Description

@paciops
paciops
opened on Oct 16, 2023
Issue body actions

Bug description

Error TypeError: internref expected is raised by __lowerInternref when a Map is passed to a function

Steps to reproduce

create a .ts file with

export function mapError(map: Map<i32, String>): void {
  console.log(`Has one? ${map.has(1)}`);
}

compile with

asc assembly/index.ts --target debug && asc assembly/index.ts --target release

in a js file

import { mapError } from "../build/debug.js";
mapError(new Map())

AssemblyScript version

0.27.13

Activity

  1. paciops
    added
    bug
    on Oct 16, 2023
  2. MaxGraey commented on Oct 16, 2023

    @MaxGraey
    MaxGraey
    on Oct 16, 2023
    Member
    More actions

    Bindings for Map and Set doesn't support yet. Here a WIP pr which partially fix that #2340. In the meantime, it's best to avoid these types for external exports

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bug

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions

      You are visitor 01402520 — GeezerVison does not store the pages you look up.
      Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.